package com.ruoyi.material.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.material.mapper.BaseFileLabelMapper;
import com.ruoyi.material.domain.BaseFileLabel;
import com.ruoyi.material.service.IBaseFileLabelService;

/**
 * 素材标签记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-07-23
 */
@Service
public class BaseFileLabelServiceImpl implements IBaseFileLabelService 
{
    @Autowired
    private BaseFileLabelMapper baseFileLabelMapper;

    /**
     * 查询素材标签记录
     * 
     * @param id 素材标签记录ID
     * @return 素材标签记录
     */
    @Override
    public BaseFileLabel selectBaseFileLabelById(Long id)
    {
        return baseFileLabelMapper.selectBaseFileLabelById(id);
    }

    /**
     * 查询素材标签记录列表
     * 
     * @param baseFileLabel 素材标签记录
     * @return 素材标签记录
     */
    @Override
    public List<BaseFileLabel> selectBaseFileLabelList(BaseFileLabel baseFileLabel)
    {
        return baseFileLabelMapper.selectBaseFileLabelList(baseFileLabel);
    }

    /**
     * 新增素材标签记录
     * 
     * @param baseFileLabel 素材标签记录
     * @return 结果
     */
    @Override
    public int insertBaseFileLabel(BaseFileLabel baseFileLabel)
    {
        return baseFileLabelMapper.insertBaseFileLabel(baseFileLabel);
    }

    /**
     * 修改素材标签记录
     * 
     * @param baseFileLabel 素材标签记录
     * @return 结果
     */
    @Override
    public int updateBaseFileLabel(BaseFileLabel baseFileLabel)
    {
        return baseFileLabelMapper.updateBaseFileLabel(baseFileLabel);
    }

    /**
     * 批量删除素材标签记录
     * 
     * @param ids 需要删除的素材标签记录ID
     * @return 结果
     */
    @Override
    public int deleteBaseFileLabelByIds(Long[] ids)
    {
        return baseFileLabelMapper.deleteBaseFileLabelByIds(ids);
    }

    /**
     * 删除素材标签记录信息
     * 
     * @param id 素材标签记录ID
     * @return 结果
     */
    @Override
    public int deleteBaseFileLabelById(Long id)
    {
        return baseFileLabelMapper.deleteBaseFileLabelById(id);
    }


    /**
     * 批量增加
     * @param saveData
     * @return
     */
     public int addBaseFileLabelList(List<BaseFileLabel> saveData){
        return baseFileLabelMapper.addBaseFileLabelList(saveData);
    }
}
